package com.zygh.questionnairesurvey.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.util.Date;

/**
 * 调查问卷
 */
@Data
@Accessors(chain = true)
@ApiModel(value = "Questionnaire对象", description = "调查问卷")
public class Questionnaire implements Serializable {
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "警号")
    private String warningsignal;

    @ApiModelProperty(value = "部门id", example = "0")
    private Integer deptId;

    @ApiModelProperty(value = "用户姓名")
    private String name;

    @ApiModelProperty(value = "部门名称")
    private String deptName;

    @ApiModelProperty(value = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;

    @ApiModelProperty(value = "修改时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updateTime;

    @ApiModelProperty(value = "问题id")
    private String lowest;

//-------------------------------------------- 非表字段 --------------------------------------------

    @ApiModelProperty(value = "父级部门名")
    @TableField(exist = false)
    private String parentName;
    @ApiModelProperty(value = "人数", example = "0")
    @TableField(exist = false)
    private Integer count;


}